<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

function follow($user_id, $follow_id) {
    if(!$user_id || !$follow_id)
        return FALSE;
    $timestamp = time();
    $query = "INSERT INTO follows(user_id, follow_id, timestamp) VALUES ('$user_id', '$follow_id', '$timestamp')";
}

function unfollow($user_id, $follow_id) {
    $query = "DELETE FROM follows WHERE user_id = '$user_id' AND follow_id = '$follow_id'";
}

function get_following_ids($user_id) {
    $query = "SELECT follow_id FROM follows WHERE user_id = '$user_id'";
}

function get_follower_ids($user_id) {
    $query = "SELECT user_id FROM follows WHERE follow_id = '$user_id'";
}

?>
